package com.openbravo.data.gui;

import com.openbravo.data.loader.IRenderString;
import java.awt.Component;
import javax.swing.DefaultListCellRenderer;
import javax.swing.JList;

public class ListCellRendererBasic extends DefaultListCellRenderer
{
  private IRenderString m_renderer;

  public ListCellRendererBasic(IRenderString paramIRenderString)
  {
    this.m_renderer = paramIRenderString;
  }

  public Component getListCellRendererComponent(JList paramJList, Object paramObject, int paramInt, boolean paramBoolean1, boolean paramBoolean2)
  {
    super.getListCellRendererComponent(paramJList, null, paramInt, paramBoolean1, paramBoolean2);
    String str = this.m_renderer.getRenderString(paramObject);
    setText((str == null) || (str.equals("")) ? " " : str);
    return this;
  }
}

/* Location:           D:\PowerFulPOS-2.30.2\openbravopos.jar
 * Qualified Name:     com.openbravo.data.gui.ListCellRendererBasic
 * JD-Core Version:    0.6.0
 */